xen: sched/credit: convert scheduling parameter to s_time_t when set
authorDario Faggioli <dfaggioli@suse.com>
Fri, 23 Feb 2018 16:41:33 +0000 (17:41 +0100)
committerGeorge Dunlap <george.dunlap@citrix.com>
Wed, 28 Feb 2018 15:06:20 +0000 (15:06 +0000)
commitcb671efbf1fae302c0ee5ebd6e23564e319babc8
treeb6dae34f3ec87bfbd72677836886cc172a0185aa
parent1c473c42199a8f4d70533c202e1c57ecd1dad35b
xen: sched/credit: convert scheduling parameter to s_time_t when set

Basically, instead of converting integers to s_time_t
at usage time (hot paths), do the convertion when the
values are set (cold paths).

This applies to the timeslice and the ratelimit
parameters of Credit1.

Note that, when changing the type of the fields of
struct csched_private (from unsigned to s_time_t),
ncpus is moved up a bit, for better packing.

Signed-off-by: Dario Faggioli <dfaggioli@suse.com>
Acked-by: George Dunlap <george.dunlap@citrix.com>
xen/common/sched_credit.c